package com.feeling.db.util;

import java.sql.Connection;

import javax.naming.Context;
import javax.naming.InitialContext;
import javax.sql.DataSource;

public class BaseDao {

	public static Connection getCon() {
		Connection con = null;
		try {
			Context ic = new InitialContext();
			DataSource dataSource = (DataSource) ic
					.lookup("java:comp/env/jdbc/feel");
			con = dataSource.getConnection();
		} catch (Exception e) {
			e.printStackTrace();
		}
		return con;
	}
}
